package cn.akwangl.design.pattern.creational.builder.v2;

import com.google.common.collect.ImmutableSet;
import org.apache.ibatis.session.SqlSessionFactoryBuilder;
import org.springframework.beans.factory.support.BeanDefinitionBuilder;

import java.util.Set;

/**
 * 建造者v2 test.
 * <p>
 * 实例<br/>
 * {@link ImmutableSet}
 * {@link BeanDefinitionBuilder}
 * {@link SqlSessionFactoryBuilder}
 * </p>
 *
 * @author youyongkun
 * @date 2021/11/24 10:43
 * @since 1.0
 */
public class Test {
    public static void main(String[] args) {
        Course course = new Course.CourseBuilder()
                .buildCourseName("Java设计模式精讲")
                .buildCoursePPT("Java设计模式精讲PPT")
                .buildCourseVideo("Java设计模式精讲视频")
                .build();
        System.out.println(course);

        Set<String> set = ImmutableSet
                .<String>builder()
                .add("a")
                .add("b")
                .build();
        System.out.println(set);
    }
}
